package com.settlement.system.model.vo;

import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

/**
 * <p>
 * 百盛订单表导入VO
 * </p>
 *
 * @author huangrensen
 * @since 2024-09-04
 */
@Schema
@Data
public class BsOmsOrderImportVo implements Serializable {
    @ExcelProperty(value = "店铺")
    private String storeName;
    @ExcelProperty(value = "内部订单号")
    private String oId;
    @ExcelProperty(value = "线上订单号")
    private String mergeSoId;
    @ExcelProperty(value = "下单时间")
    private String orderDate;
    @ExcelProperty(value = "付款日期")
    private String payDate;
    @ExcelProperty(value = "发货日期")
    private String sendDate;
    @ExcelProperty(value = "应付金额")
    private String payAmount;
    @ExcelProperty(value = "已付金额")
    private String paidAmount;
    @ExcelProperty(value = "买家实付金额")
    private String buyerPaidAmount;
    @ExcelProperty(value = "卖家实收金额")
    private String sellerIncomeAmount;
    @ExcelProperty(value = "总数量")
    private String qty;
    @ExcelProperty(value = "商品总成交金额")
    private String amount;
    @ExcelProperty(value = "状态")
    private String status;
    @ExcelProperty(value = "发货仓")
    private String sendInventory;
    @ExcelProperty(value = "支付单号")
    private String outerPayId;
    @ExcelProperty(value = "平台创建时间")
    private String created;
    @ExcelProperty(value = "子订单编号")
    private String oiId;
    @ExcelProperty(value = "原始线上订单号")
    private String rawSoId;
    @ExcelProperty(value = "线上子订单编号")
    private String outerOiId;
    @ExcelProperty(value = "商品编码")
    private String skuId;
    @ExcelProperty(value = "数量")
    private String itemQty;
    @ExcelProperty(value = "商品单价")
    private String price;
    @ExcelProperty(value = "商品金额")
    private String itemAmount;
    @ExcelProperty(value = "明细买家实付金额")
    private String itemBuyerPaidAmount;
    @ExcelProperty(value = "明细卖家实收金额")
    private String itemSellerIncomeAmount;
    @ExcelProperty(value = "原价")
    private String basePrice;
    @ExcelProperty(value = "是否赠品")
    private String zp;
    @ExcelProperty(value = "品牌")
    private String brand;

    public static Map<String, String> getKeyMap() {
        Map<String, String> map = new HashMap<>();
        map.put("店铺ID", "storeId");
        map.put("内部订单号", "oId");
        map.put("原始线上订单号", "rawSoId");
        map.put("线上子订单编号", "outerOiId");
        map.put("线上订单号", "mergeSoId");
        map.put("下单时间", "orderDate");
        map.put("付款日期", "payDate");
        map.put("发货日期", "sendDate");
        map.put("应付金额", "payAmount");
        map.put("已付金额", "paidAmount");
        // map.put("总数量", "qty");
        // map.put("商品总成交金额", "amount");
        map.put("状态", "status");
        map.put("发货仓", "sendInventory");
        map.put("支付单号", "outerPayId");
        map.put("平台创建时间", "created");

        // 明细字段
        map.put("子订单编号", "oiId");
        map.put("商品编码", "skuId");
        map.put("数量", "qty");
        map.put("卖家实收金额", "sellerIncomeAmount");
        map.put("买家实付金额", "buyerPaidAmount");
        map.put("商品单价", "price");
        map.put("商品金额", "amount");
        map.put("原价", "basePrice");
        map.put("是否赠品", "zp");
        map.put("品牌", "brand");
        return map;
    }
}
